package com.example.shop_2304.room

import androidx.room.Dao
import androidx.room.Insert
import androidx.room.OnConflictStrategy
import androidx.room.Query
import androidx.room.Update

@Dao
interface OrderDao {

    //新增
    @Insert(onConflict = OnConflictStrategy.REPLACE)
    fun insert(orderRoom: OrderRoom)
    //查询
    @Query("select * from orderRoom where orderStatus = :status")
    fun query(status:String):MutableList<OrderRoom>
    //修改
    @Update
    fun update(orderRoom: OrderRoom)
}